8. Restoring from a backup in Central Administration
In the last recipe, we saw how to back up the complete SharePoint 2010 farm in Central Administration.
In the event of a failure, that backup must be used
to restore the farm. Another reason for a restore may be new hardware
installation.
This recipe shows how to do a restore.
Getting ready
You must have administrator privileges on the SharePoint farm. A backup must have been run prior to doing this recipe.
How to do it...
Open the Central Administration screen and click Backup and Restore.
The first section is Farm Backup and Restore. Under it, click Restore from a backup.
The following page is displayed:
Select the backup you wish to restore.
A hierarchical listing of backup assets will be presented with checkboxes beside each. Check the Farm option to restore everything.
A detailed restore listing will be presented, which consists of five options.
Restore Component: This will be farm.
Restore Only Configuration Settings: The choice to restore configuration, or both content and configuration. Choose both.
Restore Options: Click Same configuration. Click OK to the resulting confirmation dialog.
Login Names and Passwords: You need to provide the password for the content databases and service applications.
New Names: This is predicated on the Restore Options. When the Same configuration option is chosen, these controls are disabled.
Click Start Restore.
How it works...
As the restore is running, the process status can be viewed from the Backup and Restore Job Status
page. Timer service jobs run the restore. In the event of errors, the
failure message column will enumerate the nature of the issue. If more
details are needed, the sprestore.log file in the backup directory will further clarify the failure.
Restore works on an apples to apples basis. This
means if a single server farm is being restored, it must be done from a
single server backup. Likewise, a multiple server farm backup cannot be
restored into a single server farm.
The service applications that are restored will not
be automatically started. They must be manually started using Central
Administration (Manage Services on server) or PowerShell.
Any trust relationships that existed must be redone.
There's more...
When restoring the farm, there are several items that must be done manually:
Alternate access mapping setting must be recreated
External data sources, used by BCS, must be reconfigured
Proxy groups must be reconfigured to have a correct association with the service application proxies
Web application must be configured with the proxy groups
More info
PowerShell can be used to perform the restore. It must be done with the Farm account's credentials, using the following command:
Restore-SPFarm -Directory <BackupFolder> -RestoreMethod Overwrite [-BackupId <GUID>]